def gpfSearch(n, f)
  while n != f
    if divides(n, f)
      n = n / f
    else
      f = f + 1
    end
  end
  return f
end
puts gpfSearch(13195)